package com.tms.goods.service.impl;

import java.util.List;

import com.tms.goods.domain.TmsGoods;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.tms.goods.mapper.TmsGoodsMapper;
import com.tms.goods.service.ITmsGoodsService;

/**
 * 订单Service业务层处理
 *
 * @author ruoyi
 * @date 2024-10-24
 */
@Service
public class TmsGoodsServiceImpl implements ITmsGoodsService
{
    @Autowired
    private TmsGoodsMapper tmsGoodsMapper;

    /**
     * 查询订单
     *
     * @param id 订单主键
     * @return 订单
     */
    @Override
    public TmsGoods selectTmsGoodsById(Long id)
    {
        return tmsGoodsMapper.selectTmsGoodsById(id);
    }

    /**
     * 查询订单列表
     *
     * @param tmsGoods 订单
     * @return 订单
     */
    @Override
    public List<TmsGoods> selectTmsGoodsList(TmsGoods tmsGoods)
    {
        return tmsGoodsMapper.selectTmsGoodsList(tmsGoods);
    }

    /**
     * 新增订单
     *
     * @param tmsGoods 订单
     * @return 结果
     */
    @Override
    public int insertTmsGoods(TmsGoods tmsGoods)
    {
        return tmsGoodsMapper.insertTmsGoods(tmsGoods);
    }

    /**
     * 修改订单
     *
     * @param tmsGoods 订单
     * @return 结果
     */
    @Override
    public int updateTmsGoods(TmsGoods tmsGoods)
    {
        return tmsGoodsMapper.updateTmsGoods(tmsGoods);
    }

    /**
     * 批量删除订单
     *
     * @param ids 需要删除的订单主键
     * @return 结果
     */
    @Override
    public int deleteTmsGoodsByIds(Long[] ids)
    {
        return tmsGoodsMapper.deleteTmsGoodsByIds(ids);
    }

    /**
     * 删除订单信息
     *
     * @param id 订单主键
     * @return 结果
     */
    @Override
    public int deleteTmsGoodsById(Long id)
    {
        return tmsGoodsMapper.deleteTmsGoodsById(id);
    }

    @Override
    public List<TmsGoods> countGoods() {
        return tmsGoodsMapper.countGoods();
    }

    @Override
    public List<TmsGoods> todoGoods() {
        return tmsGoodsMapper.todoGoods();
    }

}
